const koa = require('koa');
const koaBody = require('koa-body');
const app = new koa();
const router = require('./router');

app.use(koaBody({patchKoa: true}));
app.use(router.routes());

const port = process.env.PORT || 3000
app.listen(3000, () => {
    console.log(`server started at localhost:${port}`)
});
